Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
A message that is not in the archive (sent off-list or not yet received): gerrit.1759328122000.Ibe78949435bb2f26ad68301e2710321bf37c9486@...2715...
Attention is currently required from: flichtenheld, plaisthos.
Hello plaisthos, flichtenheld,
I'd like you to do a code review.
Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to review the following change.
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
---
M src/openvpn/push_util.c
1 file changed, 16 insertions(+), 1 deletion(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/1
src/openvpn/push_util.c +16 -1
@@ -294,10 +294,17 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the `--disable-dco` option." ); +return false; + } +int n_sent =send_push_update (arg,NULL , options,UPT_BROADCAST ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
@@ -306,6 +313,14 @@bool management_callback_send_push_update_by_cid (void *arg,unsigned long cid,const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the `--disable-dco` option." ); +return false; + } +int n_sent =send_push_update (arg, &cid, options,UPT_BY_CID ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 1
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Attention is currently required from: mrbff, plaisthos.
flichtenheld has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
Patch Set 1: Code-Review-1
(2 comments)
File src/openvpn/push_util.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/901153d2_c4cc2b99?usp=email :
PS1, Line 304: " To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
```suggestion
" To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
```Remove the quotes, we do not use them in other error messages.
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/ff703365_a978f0ce?usp=email :
PS1, Line 320: " To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
```suggestion
" To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
```Remove the quotes, we do not use them in other error messages.
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 1
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
Gerrit-Comment-Date: Wed, 01 Oct 2025 15:10:50 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Attention is currently required from: flichtenheld, plaisthos.
mrbff has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
Patch Set 1:
(2 comments)
File src/openvpn/push_util.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/023aa3c3_1be34cad?usp=email :
PS1, Line 304: " To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
Quoted 1 line
```suggestion […]
Done
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/9c773132_33d644e2?usp=email :
PS1, Line 320: " To send a PUSH_UPDATE message, be sure to use the --disable-dco option.");
Quoted 1 line
```suggestion […]
Done
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 1
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Comment-Date: Wed, 01 Oct 2025 22:09:42 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: flichtenheld <[email protected]...>
Attention is currently required from: flichtenheld, plaisthos.
Hello flichtenheld, plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Code-Review-1 by flichtenheld
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
---
M src/openvpn/push_util.c
1 file changed, 16 insertions(+), 1 deletion(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/2
src/openvpn/push_util.c +16 -1
@@ -294,10 +294,17 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg,NULL , options,UPT_BROADCAST ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
@@ -306,6 +313,14 @@bool management_callback_send_push_update_by_cid (void *arg,unsigned long cid,const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg, &cid, options,UPT_BY_CID ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 2
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Attention is currently required from: flichtenheld, mrbff, plaisthos.
cron2 has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
Patch Set 2: Code-Review+2
(1 comment)
Patchset:
PS2:
The commit message needs to contain a bit more background on why this change is made (people actually do read commit messages ;-) ).
Something like "PUSH_UPDATE does not yet function correctly with DCO when the VPN IP address is updated (new ifconfig values pushed)".
I'll add that on the fly.
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 2
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
Gerrit-Comment-Date: Sun, 05 Oct 2025 20:45:22 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Attention is currently required from: cron2, flichtenheld, mrbff, plaisthos.
Hello cron2, flichtenheld, plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to look at the new patch set (#3).
The following approvals got outdated and were removed:
Code-Review+2 by cron2
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
The PUSH_UPDATE server currently doesn't work with DCO:
For example, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops.
---
M src/openvpn/push_util.c
1 file changed, 16 insertions(+), 1 deletion(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/3
src/openvpn/push_util.c +16 -1
@@ -294,10 +294,17 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg,NULL , options,UPT_BROADCAST ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
@@ -306,6 +313,14 @@bool management_callback_send_push_update_by_cid (void *arg,unsigned long cid,const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg, &cid, options,UPT_BY_CID ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 3
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
Attention is currently required from: cron2, flichtenheld, plaisthos.
mrbff has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server if DCO is enabled
......................................................................
Patch Set 3:
(1 comment)
Patchset:
PS2:
Quoted 1 line
The commit message needs to contain a bit more background on why this change is made (people actuall […]
Done
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 3
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Comment-Date: Mon, 06 Oct 2025 08:10:31 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: cron2 <[email protected]...>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, plaisthos.
Hello cron2, flichtenheld, plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to look at the new patch set (#4).
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. In the client instead, when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the the peer info.
---
M src/openvpn/push.c
M src/openvpn/push_util.c
2 files changed, 22 insertions(+), 1 deletion(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/4
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be received while DCO is enabled, ignoring." +" To receive PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +16 -1
@@ -294,10 +294,17 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg,NULL , options,UPT_BROADCAST ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
@@ -306,6 +313,14 @@bool management_callback_send_push_update_by_cid (void *arg,unsigned long cid,const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg, &cid, options,UPT_BY_CID ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 4
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, plaisthos.
Hello cron2, flichtenheld, plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to look at the new patch set (#5).
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
---
M src/openvpn/push.c
M src/openvpn/push_util.c
M src/openvpn/ssl.c
3 files changed, 28 insertions(+), 3 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/5
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be received while DCO is enabled, ignoring." +" To receive PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +16 -1
@@ -294,10 +294,17 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg,NULL , options,UPT_BROADCAST ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
@@ -306,6 +313,14 @@bool management_callback_send_push_update_by_cid (void *arg,unsigned long cid,const char *options) { +struct multi_context *m = arg; +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return false; + } +int n_sent =send_push_update (arg, &cid, options,UPT_BY_CID ,PUSH_BUNDLE_SIZE );RETURN_UPDATE_STATUS (n_sent);
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 5
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, mrbff, plaisthos.
ordex has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
Patch Set 5:
(3 comments)
File src/openvpn/push.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/cff164a5_fe297422?usp=email :
PS5, Line 1117: msg(M_WARN, "WARN: PUSH_UPDATE messages cannot currently be received while DCO is enabled, ignoring."
I'd reword: "be received while.." -> "be processed in client mode while.."
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/c79ce5b0_07a07e3b?usp=email :
PS5, Line 1118: " To receive PUSH_UPDATE messages, be sure to use the --disable-dco option.");
I'd reword: "To receive.." -> "To be able to process.."
File src/openvpn/push_util.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/e9277b6d_e934a501?usp=email :
PS5, Line 301: if (dco_enabled(&m->top.options))
Why not doing this check only once at the beginning of send_push_update() ?
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 5
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-CC: ordex <[email protected]...>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
Gerrit-Comment-Date: Wed, 08 Oct 2025 07:42:53 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, mrbff, plaisthos.
Hello cron2, flichtenheld, plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
to look at the new patch set (#6).
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
---
M src/openvpn/push.c
M src/openvpn/push_util.c
M src/openvpn/ssl.c
M tests/unit_tests/openvpn/test_push_update_msg.c
4 files changed, 20 insertions(+), 3 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/6
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be processed in client mode while DCO is enabled, ignoring." +" To be able to process PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +7 -1
@@ -191,6 +191,13 @@int send_push_update (struct multi_context *m,const void *target,const char *msg,const push_update_type type,const int push_bundle_size) { +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return 0 ; + } +if (!msg || !*msg || !m || (!target && type !=UPT_BROADCAST )) {
@@ -294,7 +301,6 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) {
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
tests/unit_tests/openvpn/test_push_update_msg.c +1 -0
@@ -465,6 +465,7 @@ m->instances =calloc (1 ,sizeof (struct multi_instance *));struct multi_instance *mi =calloc (1 ,sizeof (struct multi_instance )); *(m->instances) = mi; + m->top.options.disable_dco = true; *state = m;return 0 ; }
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 6
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-CC: ordex <[email protected]...>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, ordex, plaisthos.
mrbff has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
Patch Set 6:
(4 comments)
File src/openvpn/push.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/3127766f_33b50006?usp=email :
PS5, Line 1117: msg(M_WARN, "WARN: PUSH_UPDATE messages cannot currently be received while DCO is enabled, ignoring."
Quoted 1 line
I'd reword: "be received while.." -> "be processed in client mode while.. […]
Done
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/c5e2e7d0_4498f1b8?usp=email :
PS5, Line 1118: " To receive PUSH_UPDATE messages, be sure to use the --disable-dco option.");
Quoted 1 line
I'd reword: "To receive.." -> "To be able to process.. […]
Done
File src/openvpn/push_util.c:
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/13c28d61_88982957?usp=email :
PS5, Line 301: if (dco_enabled(&m->top.options))
Quoted 1 line
Why not doing this check only once at the beginning of
send_push_update()?
Done
http://gerrit.openvpn.net/c/openvpn/+/1245/comment/b41cfce5_b268256b?usp=email :
PS5, Line 301: if (dco_enabled(&m->top.options))
Quoted 1 line
Why not doing this check only once at the beginning of
send_push_update()?
Done
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 6
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-CC: ordex <[email protected]...>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: ordex <[email protected]...>
Gerrit-Comment-Date: Wed, 08 Oct 2025 08:19:58 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: ordex <[email protected]...>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveAttention is currently required from: cron2, flichtenheld, mrbff, plaisthos.
ordex has posted comments on this change by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
Patch Set 6: Code-Review+2
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 6
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: ordex <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]...>
Gerrit-Attention: cron2 <[email protected]...>
Gerrit-Attention: flichtenheld <[email protected]...>
Gerrit-Attention: mrbff <[email protected]...>
Gerrit-Comment-Date: Wed, 08 Oct 2025 08:26:40 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
PATCH v6 1/1 PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveFrom: Marco Baffo <[email protected]...>
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
---
This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
This mail reflects revision 6 of this Change.
Acked-by according to Gerrit (reflected above):
Antonio Quartulli <[email protected]...>
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be processed in client mode while DCO is enabled, ignoring." +" To be able to process PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +7 -1
@@ -191,6 +191,13 @@int send_push_update (struct multi_context *m,const void *target,const char *msg,const push_update_type type,const int push_bundle_size) { +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return 0 ; + } +if (!msg || !*msg || !m || (!target && type !=UPT_BROADCAST )) {
@@ -294,7 +301,6 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) {
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
tests/unit_tests/openvpn/test_push_update_msg.c +1 -0
@@ -465,6 +465,7 @@ m->instances =calloc (1 ,sizeof (struct multi_instance *));struct multi_instance *mi =calloc (1 ,sizeof (struct multi_instance )); *(m->instances) = mi; + m->top.options.disable_dco = true; *state = m;return 0 ; }
[Openvpn-devel] [PATCH applied] Re: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
So, to wrap up the discussions we had on IRC about this patch, and the underlying issue - basically, our current implementation of PUSH_UPDATE is incompatible with DCO, for different reasons
- on the server, if PUSH_UDPATE sends new "ifconfig" or "ifconfig-ipv6" addresses for the client, DCO needs to be told ("vpn-ip" attribute of the in-kernel peer) - and this code is not there yet. Also, we might need to remove + reinstall iroutes, as those are "in the normal routing system, with the client vpn-ip next-hop" (on Linux and FreeBSD), which we do not have any code for, either.
- on the client, we current close + reopen the tun device on PUSH_UPDATE reception - which is the most simple implementation (as compared to "calculate the delta needed, and update the config"). Alas, this does not work with DCO either - here, we have no problem with "vpn-ip", as this does not matter in client/p2p mode - but here, we have KEYS to address. "Close and reopen tun" = "there is no key material in kernel for this (new) DCO peer", and thus, no packets pass.
For the client side, we do not really need to worry about DCO handling, *if* we can do the ip address / route updates in an incremental way - but this is more complex. So for 2.7.0, we decided to go with "if DCO is active, the client will signal 'no support for PUSH_UPDATE' and also refuse incoming messages (from a server that does not check the IV_ bits) with a clear message". Afterwards, the necessary changes for incremental updates get looked at.
For the server side, there is another patch coming that improves learning/forgetting vpn IP addresses in the userland hash - and a future patch could build on that, and update the information in DCO with the new peer data. But this is also no priority for 2.7.0 (as we consider PUSH_UPDATE server side to be more of a "work in progress" thing). It does work without DCO.
Thus, for now, refuse PUSH_UPDATE functionality on both ends if DCO is active on the local end.
I have not tested this beyond what the BBs do (= unit tests are now fixed and pass). The actual PUSH_UPDATE code is the same, it is just not reachable "if (dco)".
Your patch has been applied to the master branch.
commit 373178b32dfa8f272cb9322b5f0092b03c3c61c2
Author: Marco Baffo Date: Wed Oct 8 10:30:41 2025 +0200
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
Signed-off-by: Marco Baffo <[email protected]...>
Acked-by: Antonio Quartulli <[email protected]...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
Message-Id: <[email protected]...>
URL: https://sourceforge.net/p/openvpn/mailman/message/59243711/
Signed-off-by: Gert Doering <[email protected]...>--
kind regards,
Gert Doering
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archivecron2 has uploaded a new patch set (#7) to the change originally created by mrbff. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
The following approvals got outdated and were removed:
Code-Review+2 by ordex
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
Message-Id: <[email protected]...>
URL: https://sourceforge.net/p/openvpn/mailman/message/59243711/
---
M src/openvpn/push.c
M src/openvpn/push_util.c
M src/openvpn/ssl.c
M tests/unit_tests/openvpn/test_push_update_msg.c
4 files changed, 20 insertions(+), 3 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/45/1245/7
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be processed in client mode while DCO is enabled, ignoring." +" To be able to process PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +7 -1
@@ -191,6 +191,13 @@int send_push_update (struct multi_context *m,const void *target,const char *msg,const push_update_type type,const int push_bundle_size) { +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return 0 ; + } +if (!msg || !*msg || !m || (!target && type !=UPT_BROADCAST )) {
@@ -294,7 +301,6 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) {
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
tests/unit_tests/openvpn/test_push_update_msg.c +1 -0
@@ -465,6 +465,7 @@ m->instances =calloc (1 ,sizeof (struct multi_instance *));struct multi_instance *mi =calloc (1 ,sizeof (struct multi_instance )); *(m->instances) = mi; + m->top.options.disable_dco = true; *state = m;return 0 ; }
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 7
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: ordex <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
[Openvpn-devel] [S] Change in openvpn[master]: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archivecron2 has submitted this change. ( http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email )
Change subject: PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
......................................................................
PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
Message-Id: <[email protected]...>
URL: https://sourceforge.net/p/openvpn/mailman/message/59243711/
---
M src/openvpn/push.c
M src/openvpn/push_util.c
M src/openvpn/ssl.c
M tests/unit_tests/openvpn/test_push_update_msg.c
4 files changed, 20 insertions(+), 3 deletions(-)
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be processed in client mode while DCO is enabled, ignoring." +" To be able to process PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +7 -1
@@ -191,6 +191,13 @@int send_push_update (struct multi_context *m,const void *target,const char *msg,const push_update_type type,const int push_bundle_size) { +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return 0 ; + } +if (!msg || !*msg || !m || (!target && type !=UPT_BROADCAST )) {
@@ -294,7 +301,6 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) {
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
tests/unit_tests/openvpn/test_push_update_msg.c +1 -0
@@ -465,6 +465,7 @@ m->instances =calloc (1 ,sizeof (struct multi_instance *));struct multi_instance *mi =calloc (1 ,sizeof (struct multi_instance )); *(m->instances) = mi; + m->top.options.disable_dco = true; *state = m;return 0 ; }
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1245?usp=email
To unsubscribe, or for help writing mail filters, visit http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ibe78949435bb2f26ad68301e2710321bf37c9486
Gerrit-Change-Number: 1245
Gerrit-PatchSet: 7
Gerrit-Owner: mrbff <[email protected]...>
Gerrit-Reviewer: cron2 <[email protected]...>
Gerrit-Reviewer: flichtenheld <[email protected]...>
Gerrit-Reviewer: ordex <[email protected]...>
Gerrit-Reviewer: plaisthos <[email protected]...>
Gerrit-CC: openvpn-devel <[email protected]>
PATCH v7 1/1 PUSH_UPDATE: disabling PUSH_UPDATE server and client if DCO is enabled
In reply to a message not in the archiveFrom: Marco Baffo <[email protected]...>
The PUSH_UPDATE currently doesn't work with DCO.
For example, in server, if a new ifconfig is sent, the DCO doesn't receive the new peer address and the connection drops. Similarly in the client when a PUSH_UPDATE is received, the tun is closed and reopened but the DCO doesn't receive the peer info.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
Message-Id: <[email protected]...>
URL: https://sourceforge.net/p/openvpn/mailman/message/59243711/
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
---
This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1245
This mail reflects revision 7 of this Change.
Acked-by according to Gerrit (reflected above):
src/openvpn/push.c +6 -0
@@ -1112,6 +1112,12 @@ }else if (honor_received_options &&buf_string_compare_advance (&buf, push_update_cmd)) { +if (dco_enabled (&c->options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be processed in client mode while DCO is enabled, ignoring." +" To be able to process PUSH_UPDATE messages, be sure to use the --disable-dco option." ); +return PUSH_MSG_ERROR ; + }return process_incoming_push_update (c, permission_mask, option_types_found, &buf, false); }else
src/openvpn/push_util.c +7 -1
@@ -191,6 +191,13 @@int send_push_update (struct multi_context *m,const void *target,const char *msg,const push_update_type type,const int push_bundle_size) { +if (dco_enabled (&m->top.options)) + { +msg (M_WARN ,"WARN: PUSH_UPDATE messages cannot currently be sent while DCO is enabled." +" To send a PUSH_UPDATE message, be sure to use the --disable-dco option." ); +return 0 ; + } +if (!msg || !*msg || !m || (!target && type !=UPT_BROADCAST )) {
@@ -294,7 +301,6 @@ } \ }while (0 ) - bool management_callback_send_push_update_broadcast(void *arg, const char *options) {
src/openvpn/ssl.c +6 -2
@@ -1926,8 +1926,12 @@/* support for exit notify via control channel */ iv_proto |=IV_PROTO_CC_EXIT_NOTIFY ; -/* support push-updates */ - iv_proto |=IV_PROTO_PUSH_UPDATE ; +/* currently push-update is not supported when DCO is enabled */ +if (!session->opt->dco_enabled) + { +/* support push-updates */ + iv_proto |=IV_PROTO_PUSH_UPDATE ; + }if (session->opt->pull) {
tests/unit_tests/openvpn/test_push_update_msg.c +1 -0
@@ -465,6 +465,7 @@ m->instances =calloc (1 ,sizeof (struct multi_instance *));struct multi_instance *mi =calloc (1 ,sizeof (struct multi_instance )); *(m->instances) = mi; + m->top.options.disable_dco = true; *state = m;return 0 ; }